package com.maimao.model.user;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import lombok.*;

import java.io.Serializable;

/**
 * @author MaoLin Wang
 * @date 2020/11/28 10:56 上午
 */
@Setter
@Getter
@AllArgsConstructor
@NoArgsConstructor
@Builder
@TableName("mm_city")
public class City implements Serializable {
    private static final long serialVersionUID = 8078554715828010492L;

    @TableId(type = IdType.INPUT)
    private Integer code;

    private String name;

    /**
     * 省id
     */
    @TableField(value = "province_code")
    private Integer provinceCode;

    @Override
    public String toString() {
        return "City{" +
                "code='" + code + '\'' +
                ", name='" + name + '\'' +
                ", provinceCode='" + provinceCode + '\'' +
                '}';
    }

}
